package com.yamanyar.weebill.aop;

import java.util.Arrays;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.aspectj.lang.JoinPoint;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.stereotype.Component;

@Component
@Aspect
public class LoggingAspect {
	private Log log = LogFactory.getLog(this.getClass());


	@Pointcut("within(com.yamanyar.weebill.dao.*)")
	public void empTrace() {
	}

	@Before("empTrace()")
	public void logBefore() {
//		public void logBefore(JoinPoint joinPoint) {

//		log.info("The method " + joinPoint.getSignature().getName()
//				+ "() begins with " + Arrays.toString(joinPoint.getArgs()));
		
		log.info("HELLO WORLD!");
	}

}
